﻿using MQTTnet.Formatter;
using MQTTnet.Protocol;
using System;
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using System.Text;

namespace DotNetCore.CAP.MQTT
{
    public class CAPMqttOptions
    {
        public string Server { get; set; } = "localhost";
        public int Port { get; set; }
        public string ClientId { get; set; }
        public string UserName { get; set; }
        public string Password { get; set; }
        public int ConnectionPoolSize { get; set; }
        public MqttProtocolVersion Version { get; set; } =
#if NET8_0_OR_GREATER
            MqttProtocolVersion.V500
#else
            MqttProtocolVersion.V310
#endif
            ;
        public bool UseString { get; set; }
        public MqttQualityOfServiceLevel Qos { get; set; } = MqttQualityOfServiceLevel.AtLeastOnce;
    }
}
